[PATCH] util: fix seg-fault when trying to kill-subarray in anon-existing container

open_subarray returns valid fd to a container. In case of error shall return
negative value.

Signed-off-by: Marcin Labun <marcin.labun [at] intel.com>
---
util.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/util.c b/util.c
index ce03239..1680d6b 100644
--- a/util.c
+++ b/util.c
[at] [at] -1370,7 +1370,7 [at] [at] int open_subarray(char *dev, char *subarray, struct supertype *st, int quiet)
if (!quiet)
fprintf(stderr, Name ": Couldn't open %s, aborting\n",
dev);
- return 2;
+ return -2;
}

st->devnum = fd2devnum(fd);
--
1.6.4.2

--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo [at] vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Marcin.Labun [ Mo, 05 September 2011 16:17 ] [ ID #2063982 ]

Re: [PATCH] util: fix seg-fault when trying to kill-subarray in anon-existing container

On Mon, Sep 5, 2011 at 7:17 AM, Labun, Marcin <Marcin.Labun [at] intel.com> wrote:
> open_subarray returns valid fd to a container. In case of error shall return
> negative value.
>
> Signed-off-by: Marcin Labun <marcin.labun [at] intel.com>

Collides with the patch Anna submitted a month ago [1]. Just ping the
old thread.

--
Dan

[1]: http://marc.info/?l=linux-raid&m=131221282424569&w=2
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo [at] vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Dan Williams [ Di, 06 September 2011 23:46 ] [ ID #2064013 ]

Re: [PATCH] util: fix seg-fault when trying to kill-subarray in anon-existing container

On Tue, 6 Sep 2011 14:46:36 -0700 Dan Williams <dan.j.williams [at] gmail.com>
wrote:

> On Mon, Sep 5, 2011 at 7:17 AM, Labun, Marcin <Marcin.Labun [at] intel.com> wrote:
> > open_subarray returns valid fd to a container. In case of error shall return
> > negative value.
> >
> > Signed-off-by: Marcin Labun <marcin.labun [at] intel.com>
>
> Collides with the patch Anna submitted a month ago [1]. Just ping the
> old thread.
>
> --
> Dan
>
> [1]: http://marc.info/?l=linux-raid&m=131221282424569&w=2


Thanks for the ping - applied (but you know that...)

NB
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo [at] vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
NeilBrown [ Mi, 07 September 2011 06:11 ] [ ID #2064031 ]
Linux » gmane.linux.raid » [PATCH] util: fix seg-fault when trying to kill-subarray in anon-existing container

Vorheriges Thema: Q: imsm rapid recovery volume
Nächstes Thema: [PATCH] fix: segfault when killing subarray of non-existentcontainer